<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<!--表头-->
<head th:insert="common/head::headBar(${title},${desc},${keyword},~{})">
<body class="home blog  hfeed modular-title-2 navbar-sticky sidebar-none pagination-infinite_button paged-next">
<div class="site">
    <!-- 头部-->
    <head th:insert="common/top::topBar(${resCategoryModel},${loginFlag},${resUser})"/>
    <div class="header-gap"></div>

    <!--内容-->
    <div class="site-content">
        <div class="content-area">
            <main class="site-main">
                <div class="section pt-0 pb-0">
                    <div class="row">
                        <div class="home-filter--content" style="background-image: url('/static/images/pic_1.jpg');">
                            <div class="container">
                                <h3 class="focusbox-title">搜索本站精品资源</h3>
                                <p class="focusbox-desc">整合优质资源，让效率尽收眼底</p>
                                <form class="mb-0" method="get" action="/web/search.html" name="searchForm" onsubmit="return searchFormSubmit();">
                                    <div class="form-box search-properties">
                                        <div class="row">
                                            <div class="col-xs-12 col-sm-6 col-md-9">
                                                <div class="form-group mb-0">
                                                    <input type="text" class="home_search_input"  name="keywords" placeholder="输入关键词搜索..."  >
                                                </div>
                                            </div>
                                            <div class="col-xs-12 col-sm-6 col-md-3">
                                                <input type="submit" value="搜索" class="btn btn--block">
                                            </div>
                                        </div>
                                        <div class="home-search-results"></div>
                                    </div>
                                </form>
                                <script>
                                    function searchFormSubmit() {
                                        if (searchForm.keywords.value == "") {
                                            layer.msg('输入关键词搜索！', {time: 1500, icon: 5});
                                            searchForm.keywords.focus();
                                            return false;
                                        }
                                        return true;
                                    }
                                </script>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="section">
                    <div class="container">
                        <div class="row">
                            <!-- 最新资源 -->
                            <div class="col-lg-12">
                                <div class="content-area">
                                    <main class="site-main">
                                        <h3 class="section-title"
                                        ><span><i class="fa fa-th"></i><a href="/cate/freecate/index.html">最新资源</a></span>
                                        </h3>
                                        <div class="row posts-wrapper" >
                                            <th:block th:each="newArticle: ${resNewArticleList}">
                                                <div class="col-lg-1-5 col-6 col-sm-6 col-md-4 col-lg-3">
                                                        <article class="post post-grid ">
                                                        <div class="entry-media">
                                                            <div class="placeholder"
                                                                 style="padding-bottom: 66.666666666667%;">
                                                                <a target="_blank" href="#">
                                                                    <img class="lazyload" th:src="${newArticle?.titleImg}" th:alt="${newArticle?.title}">
                                                                </a>
                                                                <div class="cao-cover"><img src="/static/images/rings.svg" width="50" height="50px"></div>
                                                            </div>
                                                            <div class="entry-star">
                                                                <a href="javascript:void(0);" th:dataId="${newArticle?.id}" title="收藏文章" class="ripro-star" th:classappend="${newArticle?.cellectionFlag==0}?'':'ok'" onclick="saveCollection(this)"><i class='fa fa-star-o'></i></a>
                                                            </div>
                                                        </div>
                                                        <div class="entry-wrapper">
                                                            <a target="_blank" class="grid_author_avt" th:href="'/usershop/'+${newArticle?.createUserId}+'.html'" >
                                                                <div class="grid_author_bggo avatar bg-cover" >
                                                                    <img th:alt="${newArticle?.userName}" th:src="${newArticle?.userImg}"  class="avatar" height="40" width="40" style="border-radius: 50%;">
                                                                </div>
                                                            </a>
                                                            <header class="entry-header">
                                                                <div class="entry-meta">
                                                                    <span class="meta-category" style="align-items: center;">
                                                                        <i class="dot"></i><a target="_blank" th:href="${newArticle?.url}" rel="category" th:text="${newArticle?.categotyName}"></a>
                                                                    </span>
                                                                </div>
                                                                <h2 class="entry-title">
                                                                    <a target="_blank" th:href="'/web/art-detail/'+${newArticle?.id}+'.html'" rel="bookmark"  th:text="${newArticle?.title}"></a>
                                                                </h2>
                                                            </header>
                                                            <div class="entry-footer">
                                                                <ul class="post-meta-box">
                                                                    <li class="meta-date">
                                                                        <i class="fa fa-clock-o"></i><time style="margin-left: 5px;" th:text="${#dates.format(newArticle?.createTime, 'yyyy-MM-dd')}"></time>
                                                                    </li>
<!--                                                                    <li class="meta-price" th:styleappend="${newArticle?.freeType}==0?'display:none':''"><i class="fa fa-database"></i><span th:text="${newArticle?.money}"></span></li>-->
                                                                    <li class="meta-views">
                                                                        <i class="fa fa-eye"></i><span style="margin-left: 5px;" th:text="${#strings.isEmpty(newArticle?.lookSee)?0:newArticle?.lookSee}"></span>
                                                                    </li>
                                                                </ul>
                                                            </div>
                                                        </div>
                                                    </article>
                                                </div>
                                            </th:block>
                                        </div>
                                    </main>
                                </div>
                            </div>
                            <!-- 文章 -->
                            <th:block th:each="resFirstPageArticleDetail: ${resFirstPageArticleList}">
                                    <div class="col-lg-12" th:if="${#lists.isEmpty(resFirstPageArticleDetail.articleModelList)}?'display:none':''">
                                        <div class="content-area">
                                            <main class="site-main">
                                                <h3 class="section-title"><span><i class="fa fa-th"></i>
                                                    <a th:href="${resFirstPageArticleDetail?.url}" th:text="${resFirstPageArticleDetail?.categotyName}"></a></span>
                                                </h3>
                                                <div class="row posts-wrapper" >
                                                    <th:block th:each="newArticle: ${resFirstPageArticleDetail.articleModelList}">
                                                        <div class="col-lg-1-5 col-6 col-sm-6 col-md-4 col-lg-3">
                                                            <article class="post post-grid ">
                                                                <div class="entry-media">
                                                                    <div class="placeholder"
                                                                         style="padding-bottom: 66.666666666667%;">
                                                                        <a target="_blank" href="#">
                                                                            <img class="lazyload" th:src="${newArticle?.titleImg}" th:alt="${newArticle?.title}">
                                                                        </a>
                                                                        <div class="cao-cover"><img src="/static/images/rings.svg" width="50" height="50px"></div>
                                                                    </div>
                                                                    <div class="entry-star">
                                                                        <a href="javascript:void(0);" th:dataId="${newArticle?.id}" title="收藏文章" class="ripro-star" th:classappend="${newArticle?.cellectionFlag==0}?'':'ok'" onclick="saveCollection(this)"><i class='fa fa-star-o'></i></a>
                                                                    </div>
                                                                </div>
                                                                <div class="entry-wrapper">
                                                                    <a target="_blank" class="grid_author_avt" th:href="'/usershop/'+${newArticle?.createUserId}+'.html'" >
                                                                        <div class="grid_author_bggo avatar bg-cover">
                                                                            <img th:alt="${newArticle?.userName}" th:src="${newArticle?.userImg}"  class="avatar" height="40" width="40" style="border-radius: 50%;">
                                                                        </div>
                                                                    </a>
                                                                    <header class="entry-header">
                                                                        <div class="entry-meta">
                                                                <span class="meta-category" style="align-items: center;">
                                                                    <i class="dot"></i><a target="_blank" th:href="${newArticle?.url}" rel="category" th:text="${newArticle?.categotyName}"></a>
                                                                </span>
                                                                        </div>
                                                                        <h2 class="entry-title">
                                                                            <a target="_blank" th:href="'/web/art-detail/'+${newArticle?.id}+'.html'" th:title="${newArticle?.title}" rel="bookmark" th:text="${newArticle?.title}"></a>
                                                                        </h2>
                                                                    </header>
                                                                    <div class="entry-footer">
                                                                        <ul class="post-meta-box">
                                                                            <li class="meta-date">
                                                                                <i class="fa fa-clock-o"></i><time style="margin-left: 5px;" th:text="${#dates.format(newArticle?.createTime, 'yyyy-MM-dd')}"></time>
                                                                            </li>
<!--                                                                            <li class="meta-price" th:styleappend="${newArticle?.freeType}==0?'display:none':''"><i class="fa fa-database"></i><span th:text="${newArticle?.money}"></span></li>-->
                                                                            <li class="meta-views">
                                                                                <i class="fa fa-eye"></i><span style="margin-left: 5px;" th:text="${#strings.isEmpty(newArticle?.lookSee)?0:newArticle?.lookSee}"></span>
                                                                            </li>
                                                                        </ul>
                                                                    </div>
                                                                </div>
                                                            </article>
                                                        </div>
                                                    </th:block>
                                                </div>
                                            </main>
                                        </div>
                                    </div>
                            </th:block>
                        </div>
                    </div>
                </div>
                <div class="section">
                    <div class="container">
                        <h3 class="section-title">
                            <span><i class="fa fa-th"></i> <a href="/web/hotmsg.html">热点资讯</a></span>
                        </h3>
                        <div class="row cat-posts-wrapper">
                            <th:block th:each="artcleInfo: ${resArtList}">
                                <div class="col-lg-6">
                                    <article class="post post-list ">
                                        <div class="entry-media">
                                            <div class="placeholder" style="padding-bottom: 66.666666666667%;">
                                                <a target="_blank" href="#">
                                                    <img class="lazyload" th:src="${artcleInfo?.titleImg}" th:alt="${artcleInfo?.title}">
                                                </a>
                                                <div class="cao-cover"><img src="/static/images/rings.svg" width="50" height="50px"></div>
                                            </div>
                                            <div class="entry-star">
                                                <a href="javascript:void(0);" th:dataId="${artcleInfo?.id}" title="收藏文章" class="ripro-star" th:classappend="${artcleInfo?.cellectionFlag==0}?'':'ok'" onclick="saveCollection(this)"><i class='fa fa-star-o'></i></a>
                                            </div>
                                        </div>
                                        <div class="entry-wrapper">
                                            <header class="entry-header">
                                                <div class="entry-meta">
                                                <span class="meta-author">
                                                    <a><img th:alt="${artcleInfo?.userName}" th:src="${artcleInfo?.userImg}"  class="avatar" height="40" width="40"/>
                                                        <sapn th:text="${artcleInfo?.userName}"></sapn>
                                                    </a>
                                                </span>
                                                    <span class="meta-category">
                                                    <a target="_blank" href="/web/hotmsg.html" rel="category"> <i class="dot"></i>热点资讯</a>
                                                </span>
                                                </div>
                                                <h2 class="entry-title">
                                                    <a target="_blank" href="/" th:title="${artcleInfo?.title}" rel="bookmark" th:text="${artcleInfo?.title}"></a>
                                                </h2>
                                            </header>
                                            <div class="entry-excerpt u-text-format"></div>
                                            <div class="entry-footer">
                                                <ul class="post-meta-box">
                                                    <li class="meta-date">
                                                        <i class="fa fa-clock-o"></i><time style="margin-left: 5px;" th:text="${#dates.format(artcleInfo?.createTime, 'yyyy-MM-dd')}"></time>
                                                    </li>
                                                    <li class="meta-views">
                                                        <i class="fa fa-eye"></i><span style="margin-left: 5px;" th:text="${#strings.isEmpty(artcleInfo?.lookSee)?0:artcleInfo?.lookSee}"></span>
                                                    </li>
                                                </ul>
                                            </div>
                                        </div>
                                    </article>
                                </div>
                            </th:block>
                        </div>
                    </div>
                </div>

            </main>
        </div>
    </div>

    <!--底部-->
    <div th:insert="common/footer::footerBar(${resTags},${resLinkList})"/>
</div>
</body>
</html>
